import request from '@/utils/request'

// 查询租约管理列表
export function listLeases(query) {
  return request({
    url: '/leases/leases/list',
    method: 'get',
    params: query
  })
}

// 查询租约管理详细
export function getLeases(leaseId) {
  return request({
    url: '/leases/leases/' + leaseId,
    method: 'get'
  })
}

// 新增租约管理
export function addLeases(data) {
  return request({
    url: '/leases/leases',
    method: 'post',
    data: data
  })
}

// 修改租约管理
export function updateLeases(data) {
  return request({
    url: '/leases/leases',
    method: 'put',
    data: data
  })
}

// 删除租约管理
export function delLeases(leaseId) {
  return request({
    url: '/leases/leases/' + leaseId,
    method: 'delete'
  })
}
